Search the Bulletin

The [Electronic] Towers of Hanoi

Towers of Hanoi

Towers of Hanoi

For 20 years, Professor of Mathematics and Department Chair Stephen Maurer ’67 has been using a mathematical puzzle called The Towers of Hanoi in his Discrete Math course. The puzzle originally consisted of three wooden poles with three-or-more donut-like rings stacked up in order of size on the left-hand pole. The object is to move the rings from the left-hand pole to the right-hand pole using the fewest moves, ending with the rings in the same size order as at the start.

Each year, Maurer would put The Towers of Hanoi on reserve in Cornell Science and Engineering Library for students to practice with. “I would say to my class, if you are in the library and a tour group comes in, start playing The Towers of Hanoi,” Maurer jokes. “But don’t just zoom through it. Physically agonize over your moves, show people how hard we think.”

Some years ago, a student wrote in her final course evaluation: “Great course, but those towers became very Hanoi-ing,” Maurer reports.

With the advent of digital technology, The Towers of Hanoi is now an on-line applet—a small stand-alone software application that operates within the context of another program, usually a Web browser—where the number of rings can be controlled and move efforts are timed. (Try it at www.mazeworks.com/hanoi/index.htm)

“It’s valuable to get hands-on experience with the game to appreciate the power of the recursive methods used to solve the problems,” Maurer says. “Recursion is a term that means that a solution procedure invokes itself. The Towers of Hanoi illustrates how one can take what is seemingly a very complex problem and break it down into smaller parts, in which the solutions use the same structure as the original situation.

“Without recursive methods, most people can easily solve the game with three or four rings, but they start going in circles with more rings.”

—A.P.

Comments are closed.